﻿using System.Collections.Generic;
using PerceptiveMCAPI.Types;
//
namespace PerceptiveMCAPI
{
   internal static class campaignSendTest_Validator
   {
      // send_test_emails
      internal static Api_ValidatorMessage emails_valid( List<string> emails )
      {
         if ( emails.Count == 0 )
         {
            return Validator.FormatMsg( EnumValues.MessageLevel.Error, "emails", "No emails have been specified for test send." );
         }
         foreach ( string email in emails )
         {
            Api_ValidatorMessage msg = new Api_ValidatorMessage();
            msg = Validator.email_valid( email );
            if ( msg != null )
               return msg;    // first error will exit
         }
         return null;
      }

   }
}
